"use strict";
const I18n = require('react-native-i18n').default;
const { getLanguages } = require('react-native-i18n');
import zh from '../assets/language/zh';
import en from '../assets/language/en';
const moment = require("moment");
import 'moment/locale/zh-cn';
I18n.fallbacks = true;
I18n.translations = {
    zh,
    en
};
getLanguages().then((data) => {
    if (data[0].indexOf('en') === -1) {
        moment.locale('zh-cn');
    }
    else {
        moment.locale('en');
    }
});
function T(word) {
    return I18n.t(word);
}
export default T;
